{BEGIN searchPanel}
<style>
<!--

.searchOptions div{
	/*margin: 10px 0px 10px 10px;*/
	padding: 10px 0px 10px 10px;
}



#addOption{$id}{
	/*padding: 1px 5px 13px 5px !important;*/
}

.addOptionLink{
	margin: 1px 5px 13px 5px !important;
}

#bottomSearchButt{$id}{
	padding: 13px 1px 5px 1px !important;
}
#controlChooseMenu{$id}{
	position: absolute;			
	display: none;	
	width: auto;
	text-align: left;
	
}	

#controlsBlock_{$id}{
	/*display:table;*/
	width: 180px;
}

.srchPanelTable, .srchPanelRow{
	padding:0px !important;
}

.srchPanelRow{
	overflow: hidden;
	width: 180px;
	margin: 0px !important;
}

.srchPanelCell{
	/*padding: 2px !important;*/
	/*margin: 2px 0px 2px 2px !important;*/
	padding: 2px 0px 2px 2px !important;
	float: left; !important;	
}

.srchPanelCell2{
	/*width: 100%;*/
	width: 170px; 
	/*margin-left: 17px !important;*/
	padding-left: 17px !important;
}
.winTable{	
	/*border-collapse: collapse;*/
	border-collapse: separate;	
}

.delButt{
	visibility: hidden;
}



.addSearchControl{
	margin: 5px;
}

.critCont{
	margin: 10px 0px 0px 0px; 
}
-->
</style>



<div id="searchOptions{$id}" class="searchOptions bottomPanelBorder" {$srchOpt_attrs}>
	<!-- Search panel content -->
	<div id="srchCritTop{$id}" class="critCont" style="display: none;">
		{mlang_message SEARCH_CRITERIA}:&nbsp;
    	<input type="radio" name="srchType" {$all_checkbox}>{BEGIN all_checkbox_label}{mlang_message SEARCH_ALL}{END all_checkbox_label}
		&nbsp;&nbsp;&nbsp;
		<input type="radio" name="srchType" {$any_checkbox}>{BEGIN any_checkbox_label}{mlang_message SEARCH_ANY}{END any_checkbox_label}
	</div>
	<div id="addOption{$id}" class="addOption">
      	<a id="showHideControlChooseMenu{$id}"  class="tablelinkssearch" {$showHideCtrls_attrs}>{mlang_message SEARCH_ADD_FIELD}</a>&nbsp;&nbsp;&nbsp;
		<a id="showHideSearchType{$id}"  class="tablelinkssearch" {$showHideCtrlsOpt_attrs}>{$showHideOpt_mess}</a>		
	</div>
	<!-- choose controls div -->
	<div id="controlChooseMenu{$id}" class="controlChooseMenu" {$controlChooseMenuDiv_attrs}>
		{BEGIN addSearch_id}
			<a id="addSearchControl_id" class="addSearchControl" {$addSearchControl_id_attrs}>{$label gsp_commercial_details_Chart id}</a>
		{END addSearch_id}
		{BEGIN addSearch_bcontact_id}
			<a id="addSearchControl_bcontact_id" class="addSearchControl" {$addSearchControl_bcontact_id_attrs}>{$label gsp_commercial_details_Chart bcontact_id}</a>
		{END addSearch_bcontact_id}
		{BEGIN addSearch_account_id}
			<a id="addSearchControl_account_id" class="addSearchControl" {$addSearchControl_account_id_attrs}>{$label gsp_commercial_details_Chart account_id}</a>
		{END addSearch_account_id}
		{BEGIN addSearch_ship_mode_id}
			<a id="addSearchControl_ship_mode_id" class="addSearchControl" {$addSearchControl_ship_mode_id_attrs}>{$label gsp_commercial_details_Chart ship_mode_id}</a>
		{END addSearch_ship_mode_id}
		{BEGIN addSearch_ship_from_city}
			<a id="addSearchControl_ship_from_city" class="addSearchControl" {$addSearchControl_ship_from_city_attrs}>{$label gsp_commercial_details_Chart ship_from_city}</a>
		{END addSearch_ship_from_city}
		{BEGIN addSearch_ship_from_country}
			<a id="addSearchControl_ship_from_country" class="addSearchControl" {$addSearchControl_ship_from_country_attrs}>{$label gsp_commercial_details_Chart ship_from_country}</a>
		{END addSearch_ship_from_country}
		{BEGIN addSearch_ship_to_country}
			<a id="addSearchControl_ship_to_country" class="addSearchControl" {$addSearchControl_ship_to_country_attrs}>{$label gsp_commercial_details_Chart ship_to_country}</a>
		{END addSearch_ship_to_country}
		{BEGIN addSearch_ship_to_port}
			<a id="addSearchControl_ship_to_port" class="addSearchControl" {$addSearchControl_ship_to_port_attrs}>{$label gsp_commercial_details_Chart ship_to_port}</a>
		{END addSearch_ship_to_port}
		{BEGIN addSearch_ship_date}
			<a id="addSearchControl_ship_date" class="addSearchControl" {$addSearchControl_ship_date_attrs}>{$label gsp_commercial_details_Chart ship_date}</a>
		{END addSearch_ship_date}
		{BEGIN addSearch_remarks}
			<a id="addSearchControl_remarks" class="addSearchControl" {$addSearchControl_remarks_attrs}>{$label gsp_commercial_details_Chart remarks}</a>
		{END addSearch_remarks}
		{BEGIN addSearch_support_documents}
			<a id="addSearchControl_support_documents" class="addSearchControl" {$addSearchControl_support_documents_attrs}>{$label gsp_commercial_details_Chart support_documents}</a>
		{END addSearch_support_documents}
		{BEGIN addSearch_origin_requirements}
			<a id="addSearchControl_origin_requirements" class="addSearchControl" {$addSearchControl_origin_requirements_attrs}>{$label gsp_commercial_details_Chart origin_requirements}</a>
		{END addSearch_origin_requirements}
		{BEGIN addSearch_book_nos}
			<a id="addSearchControl_book_nos" class="addSearchControl" {$addSearchControl_book_nos_attrs}>{$label gsp_commercial_details_Chart book_nos}</a>
		{END addSearch_book_nos}
		{BEGIN addSearch_ship_status}
			<a id="addSearchControl_ship_status" class="addSearchControl" {$addSearchControl_ship_status_attrs}>{$label gsp_commercial_details_Chart ship_status}</a>
		{END addSearch_ship_status}
		{BEGIN addSearch_status}
			<a id="addSearchControl_status" class="addSearchControl" {$addSearchControl_status_attrs}>{$label gsp_commercial_details_Chart status}</a>
		{END addSearch_status}
		{BEGIN addSearch_signatory}
			<a id="addSearchControl_signatory" class="addSearchControl" {$addSearchControl_signatory_attrs}>{$label gsp_commercial_details_Chart signatory}</a>
		{END addSearch_signatory}
		{BEGIN addSearch_pre_carriage_mode}
			<a id="addSearchControl_pre_carriage_mode" class="addSearchControl" {$addSearchControl_pre_carriage_mode_attrs}>{$label gsp_commercial_details_Chart pre_carriage_mode}</a>
		{END addSearch_pre_carriage_mode}
		{BEGIN addSearch_pre_carriage_from}
			<a id="addSearchControl_pre_carriage_from" class="addSearchControl" {$addSearchControl_pre_carriage_from_attrs}>{$label gsp_commercial_details_Chart pre_carriage_from}</a>
		{END addSearch_pre_carriage_from}
		{BEGIN addSearch_pre_carriage_to}
			<a id="addSearchControl_pre_carriage_to" class="addSearchControl" {$addSearchControl_pre_carriage_to_attrs}>{$label gsp_commercial_details_Chart pre_carriage_to}</a>
		{END addSearch_pre_carriage_to}
		{BEGIN addSearch_ref_id}
			<a id="addSearchControl_ref_id" class="addSearchControl" {$addSearchControl_ref_id_attrs}>{$label gsp_commercial_details_Chart ref_id}</a>
		{END addSearch_ref_id}
	</div>
	<!-- search window controls block, make it visible in window mode and hidden in panel -->
	<table id="controlsBlock_{$id}_win" class="winTable" style="display: none;" CELLPADDING="3">
	{BEGIN searchCtrlBlock_win}			
		<tr class="winRow" {$filterRow_attrs}>	
			<td class="srchWinCell"></td>		
			<td class="srchWinCell"></td>
			<td class="srchWinCell" {$srchTypeCont_attrs_win}></td>
			<td class="srchWinCell"></td>
			<td class="srchWinCell"></td>			
		</tr>
	{END searchCtrlBlock_win}
	</table>
	<!-- add for each for get predefined fields for list search panel, not adv search, visible in panel mode and hidden in window -->	
	<div id="controlsBlock_{$id}" class="srchPanelTable">		
	{BEGIN searchCtrlBlock}			
		<div class="srchPanelRow blockBorder" {$filterDiv_attrs}>	
			<div class="srchPanelCell">{$delCtrlButt}</div>		
			<div class="srchPanelCell">{$fLabel}:&nbsp;</div>
			<div class="srchPanelCell srchPanelCell2" {$srchTypeCont_attrs}>{$searchtype}</div>
			<div class="srchPanelCell srchPanelCell2" >{$searchcontrol}</div>
			<div class="srchPanelCell srchPanelCell2" {$secCtrlCont_attrs}>{$searchcontrol1}</div>			
		</div>
	{END searchCtrlBlock}
	</div>
	<div id="bottomSearchButt{$id}" align="center" {$bottomSearchButt_attrs}>
		<span class=buttonborder><input type=button class="button" value="{mlang_message SEARCH}" {$searchbutton_attrs}></span> 
	</div>
</div>
{END searchPanel}